package bean;

/**
 * @author xwu36
 */

public enum ResponseCode {
    /**
     * Success 成功调用
     * Fail 失败调用
     * Forbidden 拒绝服务
     * Unauthorized 认证失败调用
     */
    Success(200, "API调用成功"),
    Fail(-1, "API调用失败"),
    Forbidden(301, "API拒绝服务"),
    Unauthorized(401, "API认证失败");

    private int code;
    private String msg;

    ResponseCode(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return this.code;
    }

    public String getMsg() {
        return msg;
    }
}
